//
//  TakedExpressCell.m
//  TengyunStation
//
//  Created by Johnny on 15/10/23.
//  Copyright © 2015年 xingrong. All rights reserved.
//

#import "TakedExpressCell.h"
#import "TakeExpress.h"
#import "TSHeader.h"

@implementation TakedExpressCell

- (void)awakeFromNib {
    // Initialization code
    UILabel *line = [[UILabel alloc] initWithFrame:CGRectMake(0, 79.5, 320, 0.5)];
    line.backgroundColor = LineColor;
    [self addSubview:line];
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

- (void)reloadTakedExpressCell:(TakeExpress *)takeExpress {
    _expressCompanyLabel.text = takeExpress.expressCompanyName;
    _expressIdLabel.text = [NSString stringWithFormat:@"运单号：%@",takeExpress.expressId];
    if (takeExpress.address.length > 0) {
        _positionLabel.text = [NSString stringWithFormat:@"位置：%@ / %@",takeExpress.positionNumber,takeExpress.address];
    } else {
        _positionLabel.text = takeExpress.positionNumber;
    }
}

@end
